from django.contrib.auth.models import Permission
from django.contrib.contenttypes.models import ContentType
from rest_framework import serializers

########权限管理序列化器
class PermissionSerializer(serializers.ModelSerializer):


    class Meta:
        model = Permission
        fields = "__all__"




###########权限类型序列化器##########
class ContentTypeSerializer(serializers.ModelSerializer):


    name = serializers.CharField()

    class Meta:
        model=ContentType
        fields="__all__"